import request from '@/utils/request'

// 查询教学计划列表
export function listAllPlan(query) {
  return request({
    url: '/teaching/teaching_plan/list',
    method: 'get',
    params: query
  })
}
// 查询教学计划列表
export function listPlan(query) {
  return request({
    url: '/teaching/teaching_plan/list',
    method: 'get',
    params: query
  })
}
// 查询教学计划列表
export function listPlanByStudent(query) {
  return request({
    url: '/teaching/teaching_plan/listPlanByStudent',
    method: 'get',
    params: query
  })
}
// 查询教学计划列表
export function addWorkday(query) {
  return request({
    url: '/teaching/teaching_plan/addWorkday',
    method: 'post',
    params: query
  })
}
export function addHoliday(query) {
  return request({
    url: '/teaching/teaching_plan/addHoliday',
    method: 'post',
    params: query
  })
}
// 查询教学计划列表
export function previewTeachingPlan(query) {
  return request({
    url: '/teaching/teaching_plan/preview',
    method: 'post',
    params: query
  })
}

// 查询教学计划详细
export function getTeaching_plan(id) {
  return request({
    url: '/teaching/teaching_plan/' + id,
    method: 'get'
  })
}

// 新增教学计划
export function addPlan(data) {
  return request({
    url: '/teaching/teaching_plan',
    method: 'post',
    data: data
  })
}

// 修改教学计划
export function updateTeaching_plan(data) {
  return request({
    url: '/teaching/teaching_plan',
    method: 'put',
    data: data
  })
}

// 删除教学计划
export function delTeaching_plan(id) {
  return request({
    url: '/teaching/teaching_plan/' + id,
    method: 'delete'
  })
}
